]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
background: don't leak wall clock when background changes
authorRay Strode <rstrode@redhat.com>
Fri, 15 Dec 2017 15:05:34 +0000 (10:05 -0500)
committerRay Strode <rstrode@redhat.com>
Fri, 15 Dec 2017 15:57:14 +0000 (10:57 -0500)
The background code allocates a GnomeWallClock when its first created,
but neglects to drop a reference to that clock at destroy time.
The undestroyed clocks lead to a timerfd leak that eventually prevents
the shell from functioning.

https://bugzilla.gnome.org/show_bug.cgi?id=791655

js/ui/background.js

index 1c2b83baec2c9ac09d6f4ab44f79b8f79254f9aa..3ea7900e721e1fb47e96fd3d4e5feb7409453001 100644 (file)
@@ -289,6 +289,8 @@ var Background = new Lang.Class({
             this._clock.disconnect(this._timezoneChangedId);
         this._timezoneChangedId = 0;
 
+        this._clock = null;
+
         if (this._prepareForSleepId != 0)
             LoginManager.getLoginManager().disconnect(this._prepareForSleepId);
         this._prepareForSleepId = 0;